﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace AdvancedCollectionsPerformanceTests
{
    public class ListTreePerformanceTest : TreeBasePerformanceTest
    {
        private List<int> _list;

        public ListTreePerformanceTest(string name)
            : base(name)
        {
        }

        protected override void CreateNewInstance()
        {
            _list = new List<int>();
        }

        protected override void ImplementedAdd(int item)
        {
            _list.Add(item);
        }

        protected override void ImplementedCheckRandomContains(int item)
        {
            _list.Contains(item);
        }

        protected override void ImplementedRemove(int item)
        {
            _list.Remove(item);
        }
    }
}